<!--
 * @Author: 何善万 swhe@che300.com
 * @Date: 2025-04-02 16:47:29
 * @LastEditors: 何善万 swhe@che300.com
 * @LastEditTime: 2025-04-02 17:03:41
 * @FilePath: \my-promise\index.html
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<!-- 基本的html
 -->


<!DOCTYPE html>
<head>
    <title>Promise</title>
    <script src="./index.js"></script>
</head>
<body>
    
</body>
<script>
    let promise = new Promise((reslove, reject) => {
        reslove(0)
    
})
promise.then(res => {
    console.log(res, 'res')
    return false
}).catch(err =>{
    console.log(err, 'err');
    return 1
}).then(res1 => {
    console.log(res1, 'res1')
    throw 'cuowu'
}).then(res2 => {
    console.log(res2, 'res2')
}).catch(err1 => {
    console.log(err1, 'err1')
    return '成功'
})

</script>
</html>
